package net.fltx.p2pserver;

import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
import org.springframework.context.ApplicationContext;

import java.io.IOException;

/**
 * @author fltx.net
 * @Date 2021/2/21 16:56
 * @Version 1.0
 */
@Slf4j
@SpringBootApplication
public class Bootstrap implements CommandLineRunner {

    public static void main(String[] args) throws IOException {
        SpringApplication.run(Bootstrap.class,args);

    }

    @Override
    public void run(String... args) throws Exception {
        new P2PServer().start();
        log.info("服务器已启动");
    }
}
